![]() |
GetMenuItemCommandID |
||||
Header: | Menus.h | Carbon status: | Supported | |
Obtains a menu item’s command ID.
OSErr GetMenuItemCommandID ( MenuHandle inMenu, SInt16 inItem, UInt32 *outCommandID );
A handle to the menu that contains the menu item for which you wish to get a command ID.
An integer representing the item number of the menu item.
Pass a pointer to an unsigned 32-bit integer value. On return, the value is set to the item’s command ID.
A result code.
After a successful call to MenuSelect, MenuEvent, or MenuKey, call the GetMenuItemCommandID function to get a menu item’s command ID. You can use a menu item’s command ID as a position-independent method of signalling a specific action in an application.
See also the function SetMenuItemCommandID.
This function is available with Appearance Manager 1.0 and later.
Supported in Carbon. Available in CarbonLib 1.0 and later when CarbonLib 1.0 or later is installed. Exported by CarbonLib 1.0 and later and by CarbonLib 1.0 and later.
© 2000 Apple Computer, Inc. — (Last Updated 4/14/2000)